#include "hal.h"


struct_timer timer;

/**********************************************************************************
 * Descrição:
 *
 * Paramêtro(s):
 *					-
 * Retorno:
 *					-
 **********************************************************************************/
void hal_timer_init(void){

}

/**********************************************************************************
 * Descrição:void delay_ms(uint32_t ms)
 *
 * Paramêtro(s):
 *				ms	- Valor de timer irá contar para esperar o delay.
 * Retorno:
 *				Nenhum
 **********************************************************************************/
void delay_ms(uint32_t ms){
	timer.timer_delay_ms=ms;
	while(!timer.timer_delay_ms);
}

/**********************************************************************************
 * Descrição: void hal_timers_isr(void)
 *
 * Paramêtro(s): funçao de contagens de timers e delays. Deverá inseridade dentro
 * da interrupçao de 1 ms;
 *					-
 * Retorno:
 *					-
 **********************************************************************************/
void hal_timers_isr(void){

	if(timer.timer_delay_ms){
		timer.timer_delay_ms--;
	}

}
